body {
    counter-reset: h1
}

h1.t1 {
    counter-reset: h2
}

h2.t2 {
    counter-reset: h3
}

h3.t3 {
    counter-reset: h4
}

h4.t4 {
    counter-reset: h5
}

h5.t5 {
    counter-reset: h6
}

h6.t6 {
    counter-reset: h7
}

h1.t1:before {
    counter-increment: h1;
    content: counter(h1) ". "
}

h2.t2:before {
    counter-increment: h2;
    content: counter(h1) "." counter(h2) ". "
}

h3.t3:before {
    counter-increment: h3;
    content: counter(h1) "." counter(h2) "." counter(h3) ". "
}

h4.t4:before {
    counter-increment: h4;
    content: counter(h1) "." counter(h2) "." counter(h3) "." counter(h4) ". "
}

h5.t5:before {
    counter-increment: h5;
    content: counter(h1) "." counter(h2) "." counter(h3) "." counter(h4) "." counter(h5) ". "
}

h6.t6:before {
    counter-increment: h6;
    content: counter(h1) "." counter(h2) "." counter(h3) "." counter(h4) "." counter(h5) "." counter(h6) ". "
}